<script setup lang='ts'>
import { openMallWindow } from '@/helper'
import { useRouter } from 'vue-router'

import { cooperateList, supplierBanner } from '../resource'

const { push } = useRouter()

function goSupply() {
    push('/supply')
}
</script>

<template>
    <div class="py-40 bg-#fff w-full">
        <div class="mx-auto w-1300">
            <div class="mb-40 text-30 font-700 flex justify-between items-center">
                <div>供应寻源</div>

                <div class="right-icon"
                     @click="goSupply"
                >
                    <i class="i-ep:arrow-right" />
                </div>
            </div>

            <div class="flex gap-10 justify-between">
                <div class="w-60%">
                    <div class="text-##767676 mb-20 text-20 font-500">
                        合作伙伴
                    </div>

                    <div class="flex flex-wrap justify-between">
                        <el-image v-for="item in cooperateList"
                                  :key="item"
                                  class="w-32% cursor-pointer"
                                  :src="item"
                                  fit="cover"
                                  @click="openMallWindow"
                        />
                    </div>
                </div>

                <div class="w-40%">
                    <div class="text-##767676 mb-20 text-20 font-500">
                        供应商入驻
                    </div>

                    <el-image v-if="supplierBanner"
                              class="cursor-pointer"
                              :src="supplierBanner"
                              fit="cover"
                              @click="openMallWindow"
                    />
                </div>
            </div>
        </div>
    </div>
</template>
